
<h1>XML Subfield-Finder</h1>
<br>

<%= form_tag :action =>  "showsubfield" do %>

<p>
<%= label :subfield, "Subfield (e.g. 100$a)" %>
<%= text_field_tag :subfield, @subfield%>
<%= submit_tag "search" %>
<% end %>
</p>

<% if @countno %>
<%= @tag%>$<%= @code%> has <%= @countno %> entries.

<br>
<br>
Content: <br>
<% end %>
<% if @nodes %>
  <table border="1">
    <tr>
  <% @nodes.each do |node| %>

    <td><%= node[1].to_s %></td>
    <td><%= link_to node[0].to_s, "/bnf/convert?extext[name="+node[0].to_s %></td>
  </tr>
<% end %>
</table>
<% end %>
